package com.esunny.resourcevisualization.domain.entity;

import java.sql.Timestamp;

/**
 * @version 1.0.0.0
 * @ClassName ResourceTypeEntity
 * @Description 资源类别实体
 * @Author baochencong
 * @Date 2020/9/26 13:12
 */
public class ResourceTypeEntity {

    /**
     * 资源类别实体id
     */
    private int resourceTypeEntityId;

    /**
     * 资源类别英文名
     */
    private String resourceTypeName;

    /**
     * 资源类别实体描述
     */
    private String resourceTypeEntityDescription;

    /**
     * 资源类别实体状态
     */
    private String status;

    /**
     * 资源类别实体创建人
     */
    private String createdBy;

    /**
     * 资源类别实体创建时间
     */
    private Timestamp createdTime;

    /**
     * 资源类别实体最后一次修改人
     */
    private String lastEditedBy;

    /**
     * 资源类别实体最后一次修改时间
     */
    private Timestamp lastEditedTime;

    /**
     * 是否是公共可申请资源
     */
    private boolean mayApply;

    /**
     * 资源类别实体是否被删除
     */
    private boolean deleted;

    public int getResourceTypeEntityId() {
        return resourceTypeEntityId;
    }

    public void setResourceTypeEntityId(int resourceTypeEntityId) {
        this.resourceTypeEntityId = resourceTypeEntityId;
    }

    public String getResourceTypeName() {
        return resourceTypeName;
    }

    public void setResourceTypeName(String resourceTypeName) {
        this.resourceTypeName = resourceTypeName;
    }

    public String getResourceTypeEntityDescription() {
        return resourceTypeEntityDescription;
    }

    public void setResourceTypeEntityDescription(String resourceTypeEntityDescription) {
        this.resourceTypeEntityDescription = resourceTypeEntityDescription;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getCreatedBy() {
        return createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    public String getLastEditedBy() {
        return lastEditedBy;
    }

    public void setLastEditedBy(String lastEditedBy) {
        this.lastEditedBy = lastEditedBy;
    }

    public Timestamp getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Timestamp createdTime) {
        this.createdTime = createdTime;
    }

    public Timestamp getLastEditedTime() {
        return lastEditedTime;
    }

    public void setLastEditedTime(Timestamp lastEditedTime) {
        this.lastEditedTime = lastEditedTime;
    }

    public boolean isMayApply() {
        return mayApply;
    }

    public void setMayApply(boolean mayApply) {
        this.mayApply = mayApply;
    }

    public boolean isDeleted() {
        return deleted;
    }

    public void setDeleted(boolean deleted) {
        this.deleted = deleted;
    }

    public ResourceTypeEntity() {
    }

    public ResourceTypeEntity(String resourceTypeName, String resourceTypeEntityDescription, String status) {
        this.resourceTypeName = resourceTypeName;
        this.resourceTypeEntityDescription = resourceTypeEntityDescription;
        this.status = status;
    }

    @Override
    public String toString() {
        return "ResourceTypeEntity{" +
                "resourceTypeEntityId=" + resourceTypeEntityId +
                ", resourceTypeName='" + resourceTypeName + '\'' +
                ", resourceTypeEntityDescription='" + resourceTypeEntityDescription + '\'' +
                ", status='" + status + '\'' +
                ", createdBy='" + createdBy + '\'' +
                ", createdTime=" + createdTime +
                ", lastEditedBy='" + lastEditedBy + '\'' +
                ", lastEditedTime=" + lastEditedTime +
                ", mayApply=" + mayApply +
                ", deleted=" + deleted +
                '}';
    }

    @Override
    public int hashCode() {
        return this.resourceTypeEntityId;
    }

    @Override
    public boolean equals(Object obj) {
        if (!(obj instanceof ResourceTypeEntity)){
            return false;
        }
        ResourceTypeEntity resourceTypeEntity = (ResourceTypeEntity)obj;
        return this.resourceTypeEntityId == resourceTypeEntity.resourceTypeEntityId;
    }
}
